package cn.edu.scau.cmi.linzhanyi.singleton;

import java.util.ArrayList;
import java.util.List;

public class Multipleton {
	private String name;
	private static ArrayList<Multipleton> list = new ArrayList<Multipleton>();


	
	private Multipleton(String name) {
		super();
		this.name = name;
	}

	public static List<Multipleton> getList() {
		return list;
	}

	public static boolean addList(String  name) {
		if (list.size()==10) {
			return false;
		}
		Multipleton.list.add(new Multipleton(name));
		return true;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	
}
